import java.sql.* ;
class FunSalesOrder
{
public static void main(String[] s)
{

	try
	{

	java.util.Date utilDate = new java.util.Date() ;
	java.sql.Date date = new java.sql.Date(utilDate.getTime());
	java.sql.Time time = new java.sql.Time(utilDate.getTime() );



		String[] ss = {"1006","101","ab101",date.toString(),time.toString(),"900.00"};

		String[] product_id = {"10","11"};
		String[] quantity = {"15","18"} ;
		String[] price = {"300.40","500.60"} ;
		String[] VAT = {"49.60","49.40"} ;

		//SalesOrder so = new SalesOrder(ss,product_id,quantity,price,VAT);
		// so.insertDetailsInSalesInvoice() ;  //............working successfully.............
		// so.insertDetailsInSalesInvoiceDetails() ; ////............working successfully.............

		SalesOrder so = new SalesOrder() ;

		/*   //............working successfully.............

		ResultSet rs = so.getProductDetailsOfSalesId(1006);

		while(rs.next())
		{
			System.out.println(rs.getInt(1)+" "+rs.getInt(2)+" "+rs.getInt(3)+" "+rs.getFloat(4)+" "+rs.getFloat(5));
		}

		*/



		ResultSet rs = so.getSalesDetailsBetweenDates("2012-06-20","2012-06-21");

				while(rs.next())
				{
					System.out.println(rs.getInt(1)+" "+rs.getInt(2)+" "+rs.getString(3)+" "+rs.getString(4)+" "+rs.getString(5));
		}


	}
	catch(Exception e)
	{

	}

}

}